home *** CD-ROM | disk | FTP | other *** search
/ Czech Logic, Card & Gambling Games / Logické hry.iso / hry / Robocode / robocode-setup-1.0.7.jar / extract.jar / browser.sh < prev    next >
Encoding:
Linux/UNIX/POSIX Shell Script  |  2005-03-01  |  1.8 KB  |  76 lines

  1. #!/bin/sh
  2.  
  3. # ******************************************************************************
  4. # * Copyright (c) 2001 Mathew Nelson
  5. # * All rights reserved. This program and the accompanying materials 
  6. # * are made available under the terms of the Common Public License v1.0
  7. # * which accompanies this distribution, and is available at
  8. # * http://www.robocode.net/license/CPLv1.0.html
  9. # * 
  10. # * Contributors:
  11. # *     Mathew Nelson - initial API and implementation
  12. # ******************************************************************************
  13.      
  14. # Choose your own here...
  15. #which="konqueror"
  16. #which="mozilla"
  17. #which="firefox"
  18. #which="galeon"
  19.  
  20. if [[ $which == "" ]]; then
  21.     which firefox && which="firefox-tab"
  22. fi
  23. if [[ $which == "" ]]; then
  24.     which mozilla && which="mozilla-tab"
  25. fi
  26. if [[ $which == "" ]]; then
  27.     which konqueror && which="konqueror"
  28. fi
  29. if [[ $which == "" ]]; then
  30.     which galeon && which="galeon-tab"
  31. fi
  32.  
  33. if [[ $which == "firefox" ]]; then
  34.     # New or existing firefox
  35.     firefox $1 &
  36. fi
  37.  
  38. if [[ $which == "firefox-tab" ]]; then
  39.     # Use new tab in existing firefox, or open new
  40.     firefox -remote "openURL($1,new-tab)" || firefox $1 &
  41. fi
  42.  
  43. if [[ $which == "mozilla" ]]; then
  44.     # New mozilla.
  45.     mozilla $1 &
  46. fi
  47.  
  48. if [[ $which == "mozilla-tab" ]]; then
  49.     # Use new tab in existing mozilla, or open new window.
  50.     gnome-moz-remote --remote="openURL($1,new-tab)" || gnome-moz-remote $1 &
  51. fi
  52.  
  53. if [[ $which == "mozilla-win" ]]; then
  54.     # Open new window in existing mozilla (may not work), or open new process.
  55.     gnome-moz-remote --remote="openURL($1,new-window)" || gnome-moz-remote $1 &
  56. fi
  57.  
  58. if [[ $which == "konqueror" ]]; then
  59.     konqueror $1&
  60. fi
  61.  
  62. if [[ $which == "galeon" ]]; then
  63.     # new Galeon
  64.     galeon $1 &
  65. fi
  66.  
  67. if [[ $which == "galeon-win" ]]; then
  68.     # Galeon in new window:
  69.     galeon -w $1 &
  70. fi
  71.  
  72. if [[ $which == "galeon-tab" ]]; then
  73.     # Galeon in new tab:
  74.     galeon -n $1 &
  75. fi
  76.